* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box;
    font-family: 'Helvetica Neue', Arial, sans-serif;
}
body { 
    background: #f8f9fa; 
    color: #333; 
    line-height: 1.5;
}
.container { 
    max-width: 1200px; 
    margin: 0 auto; 
    padding: 20px; 
}

/* 头部样式 */
header { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-bottom: 25px; 
    padding: 10px 0;
}
h1 { 
    font-size: 30px; 
    color: #222;
    font-weight: 600;
}
.search-form { 
    display: flex; 
    max-width: 350px; 
    width: 100%;
}
.search-form input { 
    padding: 10px 15px; 
    border: 1px solid #ddd; 
    border-radius: 4px 0 0 4px; 
    flex: 1;
    font-size: 14px;
    transition: border-color 0.2s;
}
.search-form input:focus {
    outline: none;
    border-color: #ff4500;
}
.search-form button { 
    padding: 10px 20px; 
    background: #ff4500; 
    color: white; 
    border: none; 
    border-radius: 0 4px 4px 0; 
    cursor: pointer;
    font-size: 14px;
    transition: background 0.2s;
}
.search-form button:hover {
    background: #e63e00;
}

/* 主要内容布局 */
main { 
    display: flex; 
    gap: 25px; 
}
.cart-items, .checkout-details { 
    background: white; 
    border-radius: 8px; 
    padding: 25px; 
    box-shadow: 0 4px 12px rgba(0,0,0,0.05); 
}
.cart-items { 
    flex: 2; 
}
.checkout-details { 
    flex: 1; 
    height: fit-content; 
}

/* 购物车商品列表 */
.cart-actions { 
    display: flex; 
    align-items: center; 
    padding-bottom: 18px; 
    border-bottom: 1px solid #eee; 
    margin-bottom: 20px;
}
.cart-actions input { 
    margin-right: 10px; 
}
.cart-actions button { 
    padding: 7px 14px; 
    background: #f5f5f5; 
    border: 1px solid #ddd; 
    border-radius: 4px; 
    margin-right: 12px;
    font-size: 14px;
    transition: all 0.2s;
}
.cart-actions button:hover {
    background: #f0f0f0;
    border-color: #ccc;
}

.cart-item { 
    display: flex; 
    border: 1px solid #f0f0f0; 
    border-radius: 6px; 
    padding: 20px; 
    margin-bottom: 18px;
    transition: box-shadow 0.2s;
}
.cart-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.item-shop { 
    width: 15%; 
}
.item-details { 
    display: flex; 
    flex: 1; 
    gap: 15px; 
}
.item-details img { 
    width: 90px; 
    height: 90px; 
    object-fit: cover;
    border-radius: 4px; 
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.item-info { 
    flex: 2; 
}
.item-info p:first-child {
    font-weight: 500; 
    margin-bottom: 4px;
}
.item-info p:last-child { 
    color: #ff4500; 
    font-size: 14px;
}
.item-info button { 
    background: none; 
    border: none; 
    color: #0066cc; 
    text-decoration: underline;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s;
}
.item-info button:hover {
    color: #0052a3;
}
.item-specs { 
    flex: 1; 
    color: #666; 
    font-size: 14px; 
}
.item-price, .item-quantity, .item-actions { 
    flex: 1; 
    text-align: center; 
}
.item-price {
    font-weight: 500;
}
.item-actions button { 
    background: none; 
    border: none; 
    color: #0066cc;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s;
    margin: 0 5px;
}
.item-actions button:hover {
    color: #0052a3;
}

/* 结算信息 */
.checkout-details {
    position: sticky;
    top: 20px;
}
.checkout-summary div { 
    display: flex; 
    justify-content: space-between; 
    margin-bottom: 12px; 
    padding: 6px 0;
}
.checkout-summary .total { 
    font-weight: 600; 
    font-size: 18px; 
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #eee;
}
.checkout-button { 
    width: 100%; 
    padding: 13px; 
    background: #ff4500; 
    color: white; 
    border: none; 
    border-radius: 5px; 
    font-size: 16px; 
    cursor: pointer;
    margin-top: 20px;
    transition: background 0.2s;
    font-weight: 500;
}
.checkout-button:hover {
    background: #e63e00;
}

/* 响应式布局 */
@media (max-width: 768px) {
    main { 
        flex-direction: column; 
    }
    .cart-item { 
        flex-direction: column; 
    }
    .item-shop, .item-info, .item-specs, .item-price, .item-quantity, .item-actions { 
        width: 100%; text-align: left; 
    }
    .item-actions { 
        flex-direction: row; 
        margin-top: 10px;
    }
    .checkout-details {
        position: static;
    }
}